import { post } from "../../../utils/request";
import { getCurrentTenant } from '../../../utils/utils';

const messageList = data => post("mgt/msgSource/list", { ...data, tenantCodeList: (getCurrentTenant() || { tenantCode: '' }).tenantCode });

const putOffline = data => post("mgt/msgSource/offLine", data);

const messageDept = data => post("mgt/msgSource/ownerDept", data);

const delMessage = data => post("mgt/msgSource/del", data);

const myMsgs = data => post("mgt/message/list/myMsgs", data);

const updateStatus = data => post("mgt/msgSource/updateStatus", data);

export default { messageList, putOffline, messageDept, delMessage, myMsgs, updateStatus };
